import Vue from 'vue'

export function toast (message) {
  Vue.prototype.$message({
    message: message,
    duration: 3000,
    type: 'success'
  })
}

export function success (message) {
  return toast(message)
}
export function warn (message) {
  Vue.prototype.$message({
    message: message,
    duration: 3000,
    type: 'warning'
  })
}

export function error (message) {
  Vue.prototype.$message.error({
    message: message,
    duration: 4000,
    type: 'success'
  })
}
